package team.se.tms.po;

import lombok.Data;
import team.se.tms.annotation.Regex;

import java.io.Serializable;

/**
 * 权限信息类
 *
 * @author winkyle
 * @date 2018/11/17
 * @update on 2018/12/20 by johnny
 */
@Data
public class AuthorityInfo implements Serializable {
    @Regex("^[0-9]{5}$")
    private String authorityId;
    @Regex("^[\\u4e00-\\u9fa5]{1,8}$")
    private String authorityName;
    private String authorityParentId;
    private String authorityBaseId;

    @Override
    public boolean equals(Object obj) {
        if(this.getAuthorityId().equals(((AuthorityInfo)obj).getAuthorityId())){
            return true;
        }
        return false;
    }
}
